﻿using UnityEngine;
using System;
using System.Collections;
using System.Collections.Generic;

public class TimelineNode
{
    public float time;
    public Action action;
    public TimelineNode(float _time, Action _action)
    {
        time = _time;
        action = _action;
    }
}

public class TimelineNodeCmp : IComparer<TimelineNode>
{
    public int Compare(TimelineNode a, TimelineNode b)
    {
        if (a.time < b.time)
        {
            return 1;
        }
        if (a.time > b.time)
        {
            return -1;
        }
        return 0;
    }
}
